Repository navigation
Split parts over 16-part machines, let held keys go on stop, and limit the rate per port map - #2
Merged
Merged
Conversation
A port map can now say that each of its ports leads to a 16-part module of its own. Songs for an SC-88 or SC-88Pro address the second part group with 50 xx xx and let its parts listen to port A (CHANNEL MSG RX PORT); XG songs address parts 17 and up by part number. With the option on, PartSplitter lays these out over the ports: channel messages are routed by a table of the port and channel each part receives, 5x addresses go to the partner port as 4x, MODE-1 patch common goes to both ports of the pair, and XG part numbers pick the port. Off by default, and then the splitter is not in the chain at all. The CLI's play command takes --split for the same, and counts what it sends by port.
Stopping, pausing and seeking now send a Note Off for every key the sequencer has pressed and not let go, before All Sound Off and the rest. The keys are counted per port, channel and key from the note-ons and note-offs sent, in an array made once so the playback loop still allocates nothing. The Note Offs follow the same setting and rate cap as the controllers they come before. Sound Canvas VA breaks a part in mono mode whose note was ended by All Sound Off and All Notes Off: later notes on it sound as another tone, and a GS Reset does not mend it. After _BGG_PST.MID, which holds a note on its mono channel 2 when it gives way, _AKD_PMF.MID's hi-hat on channel 2 came out as a steady pitched tone instead of noise. Letting the key go first keeps it noise, rendered through the plugin. IMPLEMENTATION.md says why under "シーク".
The limit on the bytes a second handed to each port is now a setting of the port map, beside splitting the parts, and is put in force with the map chosen for each song. Settings no longer has one for all maps: an old module that drops what comes too fast and an audio plugin that needs no limit are reached through different maps. The setting kept for all maps before is not taken over. An old settings.yaml's transferRate is read as an unknown key and dropped, so every map starts unlimited. A map added copies the limit of the map being edited, as it does its ports. IMPLEMENTATION.md says where the limit is kept, and why.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Port maps learn two things about the machines on their ports, and stopping a song stops leaving parts broken.
Split a multi-part module's parts over 16-part machines
A port map can now say that each of its ports leads to a 16-part module of its own. SC-88 and SC-88Pro songs reach their second part group with
50 xx xxand let its parts listen to port A (CHANNEL MSG RX PORT); XG songs address parts 17 and up by part number. With the option on,PartSplitterlays these out over the ports: channel messages follow a table of the port and channel each part receives,5xaddresses go to the partner port as4x, MODE-1 patch common goes to both ports of the pair, and XG part numbers pick the port. Off by default, and then the splitter is not in the chain.glosa play --splitdoes the same from the CLI.Let go of the keys still down before silencing the channels
Stopping, pausing and seeking now send a Note Off for every key still down before All Sound Off and the rest. Sound Canvas VA breaks a part in mono mode whose note is ended by All Sound Off and All Notes Off: later notes on it sound as another tone, and a GS Reset does not mend it. After
_BGG_PST.MID, which holds a note on its mono channel 2 when it gives way,_AKD_PMF.MID's hi-hat on channel 2 came out as a steady pitched tone instead of noise. Rendered through the plugin, letting the key go first keeps it noise.Keep the transfer rate limit on each port map
The bytes-a-second limit is now a setting of the port map, put in force with the map chosen for each song, and Settings no longer has one for all maps. An old module that drops what comes too fast and an audio plugin that needs no limit are reached through different maps. The old setting is not taken over: an existing
settings.yaml'stransferRateis dropped, and every map starts unlimited.Ports still wait for one another: events go out in the song's order across all ports, so a machine reached through two ports never sees a reset overtake the settings that follow it.
Testing
dotnet testin Release, 944 tests, with Brack beside and without.